export const getRandomColor = (delay = 500) => {
  return new Promise((reslove) => {
    setTimeout(() => {
      const rgb = `rgb(${getRandomNumber()}, ${getRandomNumber()}, ${getRandomNumber()})`
      reslove(rgb)
    }, delay)
  })
}

function getRandomNumber(max = 256) {
  return Math.floor(Math.random() * max)
}
